--[[

        buff.lua
        exported by excel2lua.py
        from file:buff.xlsx

--]]

local _data = {
  [1] = {id = 1,name = '破防',class = 'BuffFakeAttr',check_time = 1,chixu_count = 2,eff_time = 1,icon = 'buff11',attack_attr = 102,attack_value = 200,isper = 1,toneup = 0,from = 0,effect = '',},
  [2] = {id = 2,name = '加防',class = 'BuffFakeAttr',check_time = 1,chixu_count = 2,eff_time = 1,icon = 'buff8',attack_attr = 102,attack_value = 300,isper = 1,toneup = 1,from = 0,effect = '',},
  [3] = {id = 3,name = '流血',class = 'BuffOptAttr',check_time = 3,chixu_count = 2,eff_time = 2,icon = 'buff2',attack_attr = 103,attack_value = 300,isper = 0,toneup = 0,from = 0,effect = '',},
  [4] = {id = 4,name = '治愈',class = 'BuffOptAttr',check_time = 3,chixu_count = 2,eff_time = 2,icon = 'buff18',attack_attr = 103,attack_value = 300,isper = 1,toneup = 1,from = 101,effect = '',},
  [5] = {id = 5,name = '虚落',class = 'BuffFakeAttr',check_time = 3,chixu_count = 2,eff_time = 2,icon = 'buff15',attack_attr = 101,attack_value = 300,isper = 1,toneup = 0,from = 0,effect = '',},
  [6] = {id = 6,name = '振奋',class = 'BuffFakeAttr',check_time = 1,chixu_count = 2,eff_time = 1,icon = 'buff1',attack_attr = 101,attack_value = 300,isper = 1,toneup = 1,from = 0,effect = 'RotateArrow',},
  [7] = {id = 7,name = '振奋',class = 'BuffFakeAttr',check_time = 3,chixu_count = 2,eff_time = 2,icon = 'buff1',attack_attr = 101,attack_value = 100,isper = 0,toneup = 1,from = 0,effect = 'RotateArrow',},
  [8] = {id = 8,name = '混乱',class = 'BuffConfusion',check_time = 1,chixu_count = 2,eff_time = 1,icon = 'buff16',attack_attr = 0,attack_value = 0,isper = 0,toneup = 0,from = 0,effect = '',},
  [9] = {id = 9,name = '岩盾',class = 'BuffSheild',check_time = 3,chixu_count = 3,eff_time = 1,icon = 'buff7',attack_attr = 1,attack_value = 4000,isper = 0,toneup = 0,from = 0,effect = '',},
  [10] = {id = 10,name = '冻伤',class = 'BuffOptAttr',check_time = 3,chixu_count = 3,eff_time = 3,icon = 'buff10',attack_attr = 103,attack_value = 300,isper = 0,toneup = 0,from = 0,effect = '',},
  [11] = {id = 11,name = '灼烧',class = 'BuffOptAttr',check_time = 3,chixu_count = 3,eff_time = 3,icon = 'buff6',attack_attr = 103,attack_value = 500,isper = 1,toneup = 0,from = 0,effect = '',},
  [12] = {id = 12,name = '致盲',class = 'BuffBlind',check_time = 3,chixu_count = 3,eff_time = 1,icon = 'buff17',attack_attr = 0,attack_value = 0,isper = 0,toneup = 0,from = 0,effect = '',},
  [13] = {id = 13,name = '均分',class = 'BuffShareHurt',check_time = 1,chixu_count = 2,eff_time = 7,icon = 'buff9',attack_attr = 0,attack_value = 0,isper = 0,toneup = 0,from = 0,effect = '',},
  [14] = {id = 14,name = '愚昧',class = 'BuffProcessHurt',check_time = 1,chixu_count = 2,eff_time = 7,icon = 'buff14',attack_attr = 0,attack_value = 200,isper = 1,toneup = 0,from = 0,effect = '',},
  [15] = {id = 15,name = '援护',class = 'BuffResistHurt',check_time = 1,chixu_count = 2,eff_time = 0,icon = 'buff8',attack_attr = 0,attack_value = 0,isper = 1,toneup = 0,from = 0,effect = '',},
  [16] = {id = 16,name = '嘲讽',class = 'BuffRidicule',check_time = 1,chixu_count = 2,eff_time = 0,icon = 'buff12',attack_attr = 0,attack_value = 0,isper = 1,toneup = 0,from = 0,effect = '',},
}

local id_to_index={
   [1] = 1,
   [2] = 2,
   [3] = 3,
   [4] = 4,
   [5] = 5,
   [6] = 6,
   [7] = 7,
   [8] = 8,
   [9] = 9,
   [10] = 10,
   [11] = 11,
   [12] = 12,
   [13] = 13,
   [14] = 14,
   [15] = 15,
   [16] = 16,
}

local buff={}

function buff.length() 
   return #_data 
end 

function buff.indexOf(index) 
   return _data[index] 
end 

function buff.get(id) 
  return buff.indexOf(id_to_index[id])
end 

return buff